<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <canvas id="tutorial" width="300" height="300"></canvas>
</body>
<script>
    var canvas = document.getElementById('tutorial');
    var ctx = canvas.getContext('2d');
    ctx.fillRect(10, 10, 100, 50); // 绘制矩形，填充的默认颜色为黑色。
    ctx.strokeRect(10, 70, 100, 50);   // 绘制矩形边框
</script>
</html>